<!doctype html>
<head>
	<meta charset="utf-8"/>
	<title>人人贷投资</title>
	<style>
		.g{letter-spacing:-0.31em;*letter-spacing:normal;word-spacing:-0.43em}ul.g li,dl.g dt,dl.g dd,.g-u,.g-1,.g-1-2,.g-1-3,.g-2-3,.g-1-4,.g-3-4,.g-1-5,.g-2-5,.g-3-5,.g-4-5,.g-1-6,.g-5-6,.g-1-7,.g-1-8,.g-1-9,.g-l-w,.g-l-n,.g-r-w,.g-r-n{display:inline-block;zoom:1;*display:inline;letter-spacing:normal;word-spacing:normal;vertical-align:top}.g-1{display:block}.g-1-2{width:50%}.g-1-3{width:33.33333%}.g-2-3{width:66.66666%}.g-1-4{width:25%}.g-3-4{width:75%}.g-1-5{width:20%}.g-2-5{width:40%}.g-3-5{width:60%}.g-4-5{width:80%}.g-1-6{width:16.656%}.g-5-6{width:83.33%}.g-1-7{width:14.2756%;_width:14.169%}.g-1-8{width:12.5%}
		ul,li,dl,dt,dd,h3{margin:0;padding:0;font-size:14px;font-family:verdana;}
		dl.g {width:300px;line-height:24px;margin:0 0 5px 5px;padding:5px;}
		dl.g dt{width:90px;padding-right:10px;text-align:right;color:#555;}
		dl.g dd{width:200px;}
		.page li{margin:5px 10px;}
		.red{color:red;}
		.list h3{font-size:20px;margin:5px;color:#000;}
		.list li.completed,.list li.completed:hover{background:#F0F0F0;}
		.list li{margin:10px;width:45%;padding:10px;background:#CCEECC;border-radius:10px;box-shadow:4px 4px 4px #ccc;}
		.list li:hover{background:#DDFFDD}
		i{font-size:12px;}
	</style>
</head>
<body>
<h1>人人贷投资</h1>

<i>更新时间：<?=date('Y-m-d H:i:s', $this->v['updateTime'])?></i>
<ul class="g list">
<?php foreach($this->v['lists'] as $list):?>
	<li class="g-1-2<?php if($list['percent']=='' || $list['percent'] == 100) echo ' completed'?>">
		<h3><?=$list['name']?></h3>
		<dl class="g">
			<dt>资金:</dt>
			<dd>￥<?=$list['total']?></dd>
			<dt>借款人:</dt>
			<dd><?=$list['username']?></dd>
			<dt>类型:</dt>
			<dd><?=$list['type']?></dd>
			<dt>年利率:</dt>
			<dd<?php if ($list['rate'] > 12.5) echo ' class="red"' ?>><?=$list['rate']?>%</dd>
			<dt>期数:</dt>
			<dd<?php if ($list['month'] < 24) echo ' class="red"' ?>><?=$list['month']?></dd>
			<dt>认证级别:</dt>
			<dd><?=$list['auth_level']?></dd>
			<dt>完成进度:</dt>
			<dd><?=$list['percent'] ? $list['percent'].'%' : ''?></dd>
			<dt>剩余时间:</dt>
			<dd><?=$list['left_time']?></dd>
		</dl>
	</li>
<?php endforeach?>
</ul>
<ul class="g page">
<?php if($this->v['page'] > 1):?>
<li><a href="/api/com.renrendai/lends/">首页</a></li>
<?php else:?>
<li>首页</li>
<?php endif?>
<?php if(count($this->v['lists']) == 10):?>
<li><a href="/api/com.renrendai/lends/?_pn=<?=($this->v['page'] + 1)?>">下一页</a></li>
</li>
<?php endif?>
</ul>
</body>
